package com.jwsoft.manager.common.enums;

public enum RelationTypeEnum {
    father("1", "父亲"),
    mother("2", "母亲"),
    grandfather("3", "爷爷"),
    grandmother("4", "奶奶"),
    waigong("5", "外公"),
    waipo("6", "外婆"),
    guardian("7", "监护人");


    private String type;
    private String name;

    private RelationTypeEnum(String type, String name) {
        this.type = type;
        this.name = name;
    }

    public String getType() {
        return this.type;
    }

    public String getName() {
        return this.name;
    }

    public static RelationTypeEnum getByType(String type) {
        RelationTypeEnum[] var1 = values();
        int var2 = var1.length;

        for(int var3 = 0; var3 < var2; ++var3) {
            RelationTypeEnum typeEnum = var1[var3];
            if (typeEnum.getType().equals(type)) {
                return typeEnum;
            }
        }

        return null;
    }
}
